Type hash distribution in discovery (rep2011)#437
Conversation
|
@eboasson @ivanpauno this is ready for review |
clalancette
left a comment
There was a problem hiding this comment.
I've left a few minor things to fix.
rmw_cyclonedds_cpp/src/rmw_node.cpp
Outdated
| } | ||
| if ((qos = create_readwrite_qos(qos_policies, false)) == nullptr) { | ||
|
|
||
| type_hash = get_type_hash(type_support); |
There was a problem hiding this comment.
You could just do:
| type_hash = get_type_hash(type_support); | |
| rosidl_type_hash_t type_hash = get_type_hash(type_support); |
There was a problem hiding this comment.
I did it first this way because it's a compiler error for the declaration to come after the first goto in the function. But I'm resolving by just moving the whole thing higher up, in both cases
4fde0bc to
94e6153
Compare
clalancette
left a comment
There was a problem hiding this comment.
Two small changes to do, otherwise this looks good.
|
Same run combined for PRs ros2/rmw_dds_common#70 ros2/rmw_fastrtps#671 #437 ros2/rmw_connextdds#104 Gist: https://gist.githubusercontent.com/emersonknapp/597121a37b82d9418b14472de760c8f0/raw/b0412d81c2ae2368cb592c810496d6f92650ad68/ros2.repos |
clalancette
left a comment
There was a problem hiding this comment.
Besides the leak I think we have, this is also going to need a rebase onto the latest to pull in the latest MATCHED PRs that were merged a couple of days ago.
| rosidl_type_hash_t type_hash = rosidl_get_zero_initialized_type_hash(); | ||
| void * userdata; | ||
| size_t userdata_size; | ||
| if (dds_qget_userdata(s->qos, &userdata, &userdata_size)) { |
There was a problem hiding this comment.
I'm pretty sure we are leaking the userdata here. At least, the implementation in https://github.com/eclipse-cyclonedds/cyclonedds/blob/11b923aceb2faa506459fee6cfd708345569ac43/src/core/ddsc/src/dds_qos.c#L31 (which is what dds_qget_userdata calls) seems to allocate memory, and we don't seem to be freeing it anywhere.
There was a problem hiding this comment.
Done! Rebased (all 4 prs) and added RCPPUTILS_SCOPE_EXIT(dds_free(userdata)); in the if block.
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
…with service ids in user_data Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
661887b to
0d823ec
Compare
Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
|
Gist: https://gist.githubusercontent.com/emersonknapp/c36ca5985030eccbcaac0d0384236fbd/raw/374f6ef848452efc7e6a2b079129195ece75aeec/ros2.repos |
|
CI is in ros2/rmw_dds_common#70 (comment) |
Part of ros2/ros2#1159
Depends on ros2/rosidl#729
Depends on ros2/rmw_dds_common#70
Features:
rmw_dds_commonrmw_topic_endpoint_info_t.type_hash